from api.litemall_login import LiteLogin
from api.submit import SubmitAPI

class Test_wx_order_submit:
    TOKEN=None
    def setup_method(self):
        self.login=LiteLogin()
        self.order_submit=SubmitAPI()
        login_resp=self.login.login(test_data={"username":"user123",
                                               "password":"user123"})
        Test_wx_order_submit.TOKEN=login_resp.json().get("data")["token"]

    def teardown_method(self):
        pass
    def test01_order_submit(self):
        submit_data={"addressId":"2","cartId":"0",
                     "couponId":"0","userCouponId":"0",
                     "grouponLinkId":0,"grouponRulesId":0,
                     "message":""}
        submit_resp=self.order_submit
